package org.jivesoftware.smackx.pubsub.provider;

import java.util.List;
import java.util.Map;
import org.jivesoftware.smack.packet.PacketExtension;
import org.jivesoftware.smackx.provider.EmbeddedExtensionProvider;
import org.jivesoftware.smackx.pubsub.EventElement;
import org.jivesoftware.smackx.pubsub.EventElementType;
import org.jivesoftware.smackx.pubsub.NodeExtension;

public class EventProvider extends EmbeddedExtensionProvider
{
  protected PacketExtension createReturnExtension(String paramString1, String paramString2, Map<String, String> paramMap, List<? extends PacketExtension> paramList)
  {
    return new EventElement(EventElementType.valueOf(((PacketExtension)paramList.get(0)).getElementName()), (NodeExtension)paramList.get(0));
  }
}